Skip to content

Conversation

williasc
Copy link
Member

Simply use the "selectedPokemonId" state on line 20 in App.tsx to determine which pokemon should load in the details view.

This should make it easier to implement arrows to browse pokemons (requirement for the assignment) and to solve issue #18 "Can't click on favorites"

William M Schmidt added 2 commits September 17, 2026 23:11
In the search page a card displays pokemon details.
Ran "npm run format" before commit.
- New function and datatype in Api.tsx to get pokemon details.
- The card was added directly into App.tsx. Should be its own component maybe.
- Updated the global App.css file with card css.
@williasc williasc requested a review from a team as a code owner September 17, 2026 21:19
oscarba
oscarba previously approved these changes Sep 18, 2026
Copy link
Member

@oscarba oscarba left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Gjerne forklar litt om koden til oss når vi møtes, men LGTM :)

William M Schmidt added 3 commits September 18, 2026 13:02
No more UI code directly in App.tsx. Simply a call to the component. Passing state props.
siverne
siverne previously approved these changes Sep 18, 2026
- Improves screen reader function
Copy link
Member

@oscarba oscarba left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested and works :) LGTM

@oscarba oscarba merged commit 4705b04 into main Sep 18, 2026
@oscarba oscarba deleted the 7-select-what-information-from-the-api-is-shown-when-clicking-on-a-pokémon branch September 18, 2026 11:30
Sign in to join this conversation on GitHub.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Select what information from the API is shown when clicking on a Pokémon
3 participants